<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "dw_data_jobs".
 *
 * @property integer $id
 * @property string $job_name
 * @property string $job_pinyin
 * @property integer $job_num
 * @property integer $is_statistics
 * @property string $comments
 */
class DwDataJobs extends \yii\db\ActiveRecord
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'dw_data_jobs';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['job_name', 'job_pinyin', 'job_num'], 'required'],
            [['job_num', 'is_statistics'], 'integer'],
            [['job_name', 'job_pinyin'], 'string', 'max' => 128],
            [['comments'], 'string', 'max' => 255],
            [['job_name'], 'unique']
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'job_name' => '职位名',
            'job_pinyin' => '职位名对应的拼音',
            'job_num' => '招聘总量',
            'is_statistics' => '是否统计',
            'comments' => '备注',
        ];
    }
}
